#include <csignal>
#include <iostream>
#include <unistd.h>
using namespace std;
void sigcb(int sig) {
    cout << "捕捉到了信号：" << sig << endl;
    exit(0);
}
int main() {
    signal(SIGINT, sigcb);
    while (1) {
        cout << "Running..." << endl;
        sleep(1);
    }
    return 0;
}